<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="Keywords" content="55tuan 无敌团 团购 每一天 消费 折扣">
<meta name="Description" content="wudituan">
<title>注册会员</title>
<link href="Style/style.css" rel="stylesheet" type="text/css">
<script type="text/javascript" src="Jsript/jquery-1.js"></script>
<script type="text/javascript" src="Jsript/core2.js"></script>
</head>


<body>
	<div class="top">
		<div class="tou">
			<div class="logo"><img src="images/index_04.gif" width="243" height="95" border="0" onfocus="blur()"></div>
				<div class="city">
					<div class="name"><span id="cn" style="color:#FFF">无锡</span></div>
		 		</div>	<!--div city-->
                
                 <div id="email_list" class="search">
                        <ul>
                            <li>想知道无锡每天团购什么吗？</li>  
                            <li>  
                                 <div class="box">
                                    <div class="box_1">
                                     <form name="dingyue">
                                        <input name="dingyue_email" id="dingyue_email" type="text" class="inputBg" style="color:#666666;font-size:12px;" value="免费订阅，请输入你的Email..." onclick="this.value=&#39;&#39;">
                                        <input type="button" class="bnt_dingyu" onclick="add_email_list();">
                                     </form>
                                    </div>
                                </div>
                                <script type="text/javascript">
								  	  function add_email_list()
									  {
										 var dingyueemail = document.dingyue.dingyue_email.value;
										 if (dingyueemail.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) != -1){
											 Ajax.call('user.php?act=email_list&job=add&email=' + email.value, '', rep_add_email_list, 'GET', 'TEXT');
										 }
										 else{	
											  alert("对不起，您的Email地址格式不正确");
											  return;
										 }
									  }									 
								</script>								
                            </li>
                        </ul>
                 </div>    		
	</div><!--div tou-->
   
    <div class="daohang">	
		<div class="wenzi">
			<ul>
				<li><a href="index.php" onfocus="blur()">今日团购</a></li>
				<li><a href="history.php" onfocus="blur()">往期团购</a></li>
				<li><a href="aboutus.php" onfocus="blur()">玩转无敌团</a></li>
				<li><a href="faq.php" onfocus="blur()">常见问题</a></li>
			</ul>
		</div>	
		<div class="yjfl"><a href="affiliate.php">邀请好友购买返 10 元</a></div>
		<{if ($login_status == LOGINSTATUS_OFF)}>
		<div class="login">
			<div class="denglu">
			<ul>
                <script type="text/javascript" src="Jsriptles/transport.js"></script>
				<script type="text/javascript" src="Jsript/utils.js"></script>               
                <font id="MEMBERZONE">
                	<div id="append_parent"></div>
					<div class="daohang_right_logout" style="float:right;">
                        <ul>
                            <li><a href="login.php">登录</a></li>
                            <li><a href="register.php">注册</a></li>
                        </ul>
                    </div>
               </font>
			</ul>
		</div><!--div login-->
		<{else}>
		<div class="login"> 
				<div class="denglu"> 
				<ul> 
                	<script type="text/javascript" src="js/transport.js"></script><script type="text/javascript" src="js/utils.js"></script>               
                    <font id="MEMBERZONE"> 
               		<div id="append_parent"></div> 
					<div class="daohang_right_login" style="float:right;"> 
    					<ul style="padding-left:10px;"> 
        					<li style="width:100px;"> 
           						<{$login_user}></li> 
        					<li><a href="#" onMouseOver="showmenu()">我的窝窝</a></li> 
        					<li><a href="logout.php">退出</a></li> 
    					</ul> 
					</div> 
               		</font> 
				</ul> 
		
				<div id="menu" onMouseOut="hidemenu()"  onMouseOver="showmenu()"  class="menu" style="position:absolute; z-index:2; margin-left:136px; width:100px; height:400px; margin-top:0px; display:none"> 
                 <ul> 
					  <li><a href="#" >我的窝窝</a></li
                      ><li><a href="order.php" >我的订单</a></li> 
                      <li><a href="user.php" >帐号设置</a></li> 
                      <li><a href="affiliate.php" >我的邀请</a></li> 
                      <li><a href="account.php" >账户余额</a></li>                        
  					  <li><a href="comment.php" >我的留言</a></li>      
                 </ul>                      
                </div> 
			</div>	 
		</div> <!--div login-->
		<{/if}>
	</div>	
</div><!--div daohang-->	    
</div><!--div top-->






<script language="javascript">
	
	function showmenu()
	{		
		var menu = document.getElementById('menu');
		menu.style.display = 'block';
	}
	
	function hidemenu()
	{
		var menu = document.getElementById('menu');
		menu.style.display = 'none';
	}
</script>








<div class="content">
 <div class="contenter">      
        <div class="left">
        <div class="xiangxi01">
            <div class="middle01">
            	<div class="ywtgwz">
                    <div class="denglu01" style="width:300px;">
                        注册
                    </div>
                    <div class="clear"></div>
                </div>
               
                <form action="" method="post" name="formUser" style="padding:30px;">
                  <table width="500px" style="margin-left:10px" border="0" align="left" cellpadding="5" cellspacing="3">
                    <tbody><tr>
                      <td align="right" style="padding-right:15px;  font-size:14px ;padding-top:15px;">Email</td>
                      <td style="padding-top:15px">
                      <input name="email" type="text" size="35" id="email" class="inputBg" onfocus="intips('email_display')" onblur="outtips('email_display')" >
                        <span style="color:#FF0000"> *</span>
                      </td>
                    </tr>
                    <tr height="18px;">
                        <td>
                        <td><div id="email_display" style="display:block; font-size:12px;color:#999" class="" >请输入您的Email地址，用于登陆网站或者找回密码</div>
						</td>
                    </tr>
                    <tr>
                      <td align="right" style="padding-right:15px; font-size:14px; width:80px; padding-top:20px;">用户名</td>
                      <td style="padding-top:20px">
                      <input name="username" type="text" size="35" id="username" class="inputBg" onfocus="intips('username_display')" onblur="outtips('username_display')">
                        <span style="color:#FF0000"> *</span>
                      </td>
                    </tr>
                    <tr height="18px;">
                        <td>
                        <td><div id="username_display" style="display:block; font-size:12px; color:#999" class="">请输入用户名，长度为6~31个字符，不能有特殊字符</div>
                        </td>
                    </tr>
                    <tr>
                      <td align="right" style="padding-right:15px;  font-size:14px; padding-top:15px;">密码</td>
                      <td style="padding-top:15px">
                      <input name="password" type="password" id="password1" class="inputBg" size="35" onfocus="intips('password_display')" onblur="outtips('password_display')">
                        <span style="color:#FF0000"> *</span>
                      </td>
                    </tr>
                    <tr height="18px;">
                        <td>
                        <td><div id="password_display" style="display:block; font-size:12px;color:#999" class="">请输入密码，长度为6~12个字符</div>
                        </td>
                    </tr>
                   
                    <tr>
                      <td align="right" style="padding-right:15px; font-size:14px; padding-top:15px; ">确认密码</td>
                      <td style="padding-top:15px">
                      <input name="confirm_password" type="password" id="conform_password" class="inputBg" size="35" onfocus="intips('password2_display')" onblur="outtips('password2_display')">
                        <span style="color:#FF0000"> *</span>
                      </td>
                    </tr>
                    <tr height="18px;">
                        <td>
                        <td><div id="password2_display" style="display:block; font-size:12px;color:#999" class="">请再次输入您的密码</div>
                        </td>
                    </tr>
                    
                    <tr>
                      <td>&nbsp;</td>
                      <td style="padding-top:30px; padding-bottom:50px;">
                      <input name="act" type="hidden" value="act_register">
                      <input type="hidden" name="back_act" value="">
                      <input class="buybutton" type="submit" value="立即注册" onclick="submitUser()">
                      </td>
                    </tr> 
                  </tbody>
                 </table>
                  
                </form>
                <div class="clear"></div> 
            </div>
            <div class="di01"></div>
        </div>
        <div class="clear"></div> 
    </div>     
 	<div class="right">
    	 <div class="gobuy">
            <div class="gobuy_b">
                <h3>已有窝窝团账号</h3>
              <p>直接<a href="login.php">登录！</a>
              </p>
               <p style="height:20px;font-size:12px;"><a href="password.php">忘记密码？</a></p>
            </div>
            <div class="gobuy_c"></div>
        </div>   
 	</div>
    <div class="clear"></div>
    	 
	
<div class="blank"></div>
</div>
</div>











 <div class="bottom">
	<div class="fkyj"></div>
		<div class="dibuwz">
			<div class="us">
                <ul>
                    <li><strong>用户帮助</strong></li>
                    <li class="grey"><a href="aboutus.php">玩转无敌团</a></li>
                    <li class="grey"><a href="faq.php">常见问题</a></li>
                </ul>
            </div>
            <div class="us">
                <ul>
                    <li><strong>获取更新</strong></li>
                    <li class="grey"><a target="_blank" href="">无敌团sina微博</a></li>
                    <li class="grey"><a target="_blank" href="">无敌团开心网主页</a></li>
                    <li class="grey"><a target="_blank" href="">无敌团豆瓣小组</a></li>
                    <li class="grey"><a href="">RSS订阅</a></li>
                </ul>
            </div>
            <div class="us">
                <ul>
                    <li><strong>商务合作</strong></li>
                    <li class="grey"><a href="groupby_message.php">提供团购信息</a></li>
                    <li class="grey"><a href="">友情链接</a></li>
                </ul>
            </div>
            <div class="us">
                <ul>
                    <li><strong>公司信息</strong></li>
                    <li class="grey"><a href="">关于我们</a></li>
                    <li class="grey"><a href="">媒体报道</a></li>
                    <li class="grey"><a href="contact.php">加入我们</a></li>
                    <li class="grey"><a href="privacy.php">隐私声明</a></li>
                    
                </ul>
           </div>
           
	   	   <div class="dilogo"><a href="http://www.55tuan.com/#"><img src="images/dilogo.gif" width="244" height="139" border="0"></a></div>
	</div><!--div dibuwz-->  
    
    
	<div class="banquan">&#169; 2010 55tuan.com 京ICP证100702号</div>
	<div align="center">
    	<img src="images/zhifubao_teyueshangjia.jpg">
    </div>
 </div><!--div bottom-->  



</body> 
</html> 

<script language="javascript">
	var youMail;
	var youuserName;
	var youpassWord;
	var youpassWord2;
	

	
	function intips(id){
		switch (id){
			case 'email_display':{
				if(document.formUser.email.value==""){		
					document.getElementById(id).style.display='block';
					document.getElementById(id).style.color ='#999';
					$('#email_display').html("请输入您的Email地址");
				}
				break;
			}
			case 'username_display':{
				if(document.formUser.username.value==""){		
					document.getElementById(id).style.display='block';
					document.getElementById(id).style.color ='#999';
					$('#username_display').html("请输入用户名");
				}
				break;
			}
			case 'password_display':{
				if(document.formUser.password.value==""){		
					document.getElementById(id).style.display='block';
					document.getElementById(id).style.color ='#999';
					$('#password_display').html("请输入密码");
				}
				break;
			}
			case 'password2_display':{
				if(document.formUser.confirm_password.value==""){		
					document.getElementById(id).style.display='block';
					document.getElementById(id).style.color ='#999';
					$('#password2_display').html("请确认您的密码");
				}
				break;
			}
		}
	}
	
	function outtips(id){
		switch (id){					
			case 'email_display':{						
				if(document.formUser.email.value!=""){	
					youMail = check_email();	
					if(youMail == true){							
						
						var theInputEmail = document.formUser.email.value;
						checkEmail_ajax(theInputEmail);
						//显示正确的标志
					}
					else{
						document.getElementById(id).className='';
						document.getElementById(id).style.color ='#ff0000';
						$('#email_display').html("您的Email地址格式不正确");
					}
				}
				break;
			}
			case 'username_display':{
				if(document.formUser.username.value!=""){	
					youuserName = check_username();	
					if(youuserName == true){							
						document.getElementById(id).className='myduihao';
						document.getElementById(id).style.color ='#999';
						var theInputUsername = document.formUser.username.value;
						//checkUsername_ajax(theInputUsername);
						//显示正确的标志
					}
					else{
						document.getElementById(id).className='';
						document.getElementById(id).style.color ='#ff0000';
						$('#username_display').html("您输入的用户名格式不正确");
					}
				}
				break;
			}
			case 'password_display':{
				if(document.formUser.password.value!=""){	
					youpassWord = check_passWord();	
					if(youpassWord == true){							
						document.getElementById(id).style.display='block';
						document.getElementById(id).className='myduihao';
						document.getElementById(id).style.color ='#999';
						$('#password_display').html("您输入的密码正确");
						//显示正确的标志
					}
					else{
						document.getElementById(id).className='';
						document.getElementById(id).style.color ='#ff0000';
						$('#password_display').html("您输入的密码格式不正确");
					}
				}
				break;
			}
			case 'password2_display':{
				if(document.formUser.confirm_password.value!=""){	
					youpassWord2 = check_confirmpassWord();	
					if(youpassWord2 == true){							
						document.getElementById(id).style.display='block';
						document.getElementById(id).className='myduihao';
						document.getElementById(id).style.color ='#999';
						$('#password2_display').html("您输入的密码正确");
						//显示正确的标志
					}
					else{
						document.getElementById(id).className='';
						document.getElementById(id).style.color ='#ff0000';
						$('#password2_display').html("您两次输入的密码不一致");
					}
				}
				break;
			}
		
			
		}
		 
		 function check_email() {
			 var theInputEmail = document.formUser.email.value;	 
			 if (theInputEmail.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) != -1)	{						  
				  return true;			 					
			 }
			 else{
				  return false;
			 }
		 }
		 function check_username() {
			 var theInputUsername = document.formUser.username.value;
			 if (theInputUsername.search(/^[a-zA-Z]\w{5,30}$/) !=-1){							  
				   return true;
			 }
			 else{
				  return false;
			 }
		 }
		 function check_passWord() {
			 var theInputpassWord = document.formUser.password.value;
			 if (theInputpassWord.search(/^\w{6,12}$/) !=-1)							  
				 return true;
			 else
				return false;
		 }
		  function check_confirmpassWord() {
			 var theInputpassWord = document.formUser.password.value;
			 var theInputpassWord2 = document.formUser.confirm_password.value;
			 if (theInputpassWord==theInputpassWord2)							  
				 return true;
			 else
				return false;
		 }
		
	}
</script>

<script language="javascript"> 
	function submitUser(){
		var InputEmail = document.formUser.email.value;
		if (InputEmail.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) != -1){
		}
		else{	
			alert("对不起，您的Email地址格式不正确");
			return;
		}
		 var theInputUsername = document.formUser.username.value;
		 if (theInputUsername.search(/^[a-zA-Z]\w{5,30}$/) !=-1){
		 }
		 else{
		 	alert("对不起，您用户名格式不正确");
			return;
		 }
		  var theInputpassWord = document.formUser.password.value;
		  if (theInputpassWord.search(/^\w{6,12}$/) !=-1){
		  }
		  else{
			alert("对不起，您的密码格式不正确");
			return;
		  }
		  var theInputpassWord2 = document.formUser.confirm_password.value;
		  if (theInputpassWord!=theInputpassWord2){
		  	alert("对不起，您两次输入的密码不一致");
			return;
		  }
		  else{
			  
		  }
	}
</script>			
<script language="javascript"> 
	var xmlHttp;
	function checkEmail_ajax(str){	
  		xmlHttp=GetXmlHttpObject()

  		if (xmlHttp==null){
    		alert ("您的浏览器不支持AJAX！");
    	}
		
		var url="ajax/check_account.php";
		url=url+"?q="+str;
		url=url+"&sid="+Math.random();
		//$('#email_display').html(url);
		xmlHttp.onreadystatechange=stateChanged;
		xmlHttp.open("GET",url,true);
		xmlHttp.send(null);
		
		return;
	}
	
	function stateChanged() 
	{ 
		if (xmlHttp.readyState==4)
		{ 
			var retStr = xmlHttp.responseText;
			if(retStr == "false"){
				document.getElementById('email_display').className='myduihao';
				document.getElementById('email_display').style.color ='#999';
				$('#email_display').html("恭喜您，您的Email可以使用");
			}
			else{
				document.getElementById('email_display').className='';
				document.getElementById('email_display').style.color ='#ff0000';
				$('#email_display').html("您的Email地址已经被注册了");
			}
		}
	}
		
		
		function GetXmlHttpObject()
		{
		  var xmlHttp=null;
		  try
			{
			// Firefox, Opera 8.0+, Safari
			xmlHttp=new XMLHttpRequest();
			}
		  catch (e)
			{
			// Internet Explorer
			try
			  {
			  xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
			  }
			catch (e)
			  {
			  xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
			  }
			}
		return xmlHttp;
		}
</script>

			